import service from '@/utils/request'
// 封装登录的API
export function login (data) {
  return service({
    url: '/sys/login',
    method: 'post',
    data
  })
}
// 封装获取用户资料的API
export function getInfo () {
  return service({
    url: '/sys/profile'
  })
}
// 封装退出登录的API
export function logout () {
  return service({
    url: '/vue-admin-template/user/logout',
    method: 'post'
  })
}
// 封装更新密码的API
export function updatePassword (data) {
  return service({
    url: '/sys/user/updatePass',
    method: 'put',
    data
  })
}
